function getServerHost() {
  return "http://wxsd1.unisk.cn/freet/"
}
window.alert = function (b) {
  var c = document.createElement("IFRAME");
  c.style.display = "none",
    c.setAttribute("src", "data:text/plain,"),
    document
    .documentElement
    .appendChild(c),
    window
    .frames[0]
    .window
    .alert(b),
    c
    .parentNode
    .removeChild(c)
};

function preventMove() {
  document
    .addEventListener("touchmove", function (b) {
      b.preventDefault()
    }, {
      passive: !1
    })
}

function GetRequest() {
  var b = location.search,
    c = {};
  if (-1 != b.indexOf("?")) {
    var d = b.substr(1);
    d = d.split("&");
    for (var i = 0; i < d.length; i++)
      c[d[i].split("=")[0]] = decodeURIComponent(d[i].split("=")[1])
  }
  return c
}

function judgePhone() {
  var b = navigator.userAgent;
  if (-1 < b.indexOf("Android") || -1 < b.indexOf("Linux"))
    return {
      type: "Android",
      val: 0
    };
  return -1 < b.indexOf("iPhone") ? {
      type: "ios",
      val: 1
    } :
    -1 < b.indexOf("Windows Phone") ? {
      type: "wPhone",
      val: 2
    } :
    void 0
}

function scroll(b) {
  var c = new iScroll(b, {
    useTransform: !1,
    vScroll: !1,
    hScroll: !0,
    hScrollbar: !1,
    checkDOMChanges: !0,
    hideScrollbar: !0,
    onBeforeScrollStart: function onBeforeScrollStart(d) {
      for (var i = d.target; 1 != i.nodeType;)
        i = i.parentNode;

      "SELECT" != i.tagName && "INPUT" != i.tagName && "TEXTAREA" != i.tagName && "A" != i.tagName && "IMG" != i.tagName && d.preventDefault()
    },
    onScrollMove: function onScrollMove() {
      $("#" + b).trigger("scroll")
    },
    onTouchStart: function onTouchStart() {},
    onTouchEnd: function onTouchEnd() {},
    onScrollEnd: function onScrollEnd() {}
  });
  return c
}
window
  .addEventListener("orientationchange", function () {
    0 !== window.orientation && alert("\u8BF7\u7AD6\u5C4F\u6D4F\u89C8")
  }, !1);

function checkMobile(b) {
  var c = /^1\d{10}$/;
  return !!c.test(b)
}

function closeBar(b, c) {
  $(b)
    .click(function () {
      $(c)
        .addClass("slideOutUp")
        .removeClass("slideInDown")
    })
}

function showBar(b, c) {
  $(b)
    .click(function () {
      $(c)
        .addClass("slideInDown")
        .removeClass("slideOutUp none")
    }),
    $(b).off("click")
}

function autoshowBar(b) {
  $(b)
    .addClass("slideInDown")
    .removeClass("slideOutUp none")
}

function autocloseBar(b) {
  $(b)
    .addClass("slideOutUp ")
    .removeClass("slideInDown")
}